WordPress

推荐列表 站点导航

当前位置:首页 > 建站教程 > WordPress >

WordPress主题开发内容相关编写

来源:网络整理  作者:  发布时间:2020-12-15 02:08
WordPress主题开发内容相关编写,内容分内容列表和内容详情两部分。首先说下列表文章标题h3class=titleahref=lt...

文章标题

<div>

<?php the_time('Y年n月j日') ?>

<?php endwhile; ?>

<p><?php previous_posts_link('<< 查看新文章', 0); ?> <span><?php next_posts_link('查看旧文章 >>', 0); ?></span></p>

首先说下列表

文章标签

添加编辑按钮

阅读全文

<h3><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h3>

没有文章!

<!-- Column 1 /Content -->

<?php if (have_posts()) : the_post(); update_post_caches($posts); ?>

<?php endif; ?>

WordPress主题开发内容相关编写 (https://www.wpmee.com/) WordPress开发教程 第1张

<?php comments_popup_link('0 条评论', '1 条评论', '% 条评论', '', '评论已关闭'); ?>

基本上,一个页面的内容已经包括了,大家根据自己的需求自定义的Diy

<?php the_title(); ?> 输出文章的标题

<?php else : ?>

<?php endif; ?>

<?php the_excerpt(); ?>

分页

显示评论数

内容

添加文章内容

<?php the_tags('标签:', ', ', ''); ?> 标签

<?php the_permalink(); ?> 输出文章的URL链接

接下来说下单页

</div>

添加日期

<?php if (have_posts()) : while (have_posts()) : the_post(); ?>

<a href="<?php the_permalink(); ?>">阅读全文</a>

<?php get_sidebar(); ?>

<?php else : ?>

函数详解

文章循环

输出找不到文章

<?php edit_post_link('编辑', ' • ', ''); ?>

内容

<?php the_tags('标签:', ', ', ''); ?>

可以直接很使用如下

<?php the_content('阅读全文...'); ?>

相关热词:

本站内容来源于网络,如有侵权请与我们联系,我们会及时删除,我们深感抱歉!
注:本站所有信息仅供用于网络技术学习参考,学习中请遵循相关法律法规!

本文地址: https://v30.fanwenzhu.com/jz/wp/3972.shtml

Copyright © www.juheyunku.com      关于 | 合作 | 声明 | 联系 | 更新 | 地图 | Tags

WordPress主题开发内容相关编写

2020-12-15 编辑:

文章标题

<div>

<?php the_time('Y年n月j日') ?>

<?php endwhile; ?>

<p><?php previous_posts_link('<< 查看新文章', 0); ?> <span><?php next_posts_link('查看旧文章 >>', 0); ?></span></p>

首先说下列表

文章标签

添加编辑按钮

阅读全文

<h3><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h3>

没有文章!

<!-- Column 1 /Content -->

<?php if (have_posts()) : the_post(); update_post_caches($posts); ?>

<?php endif; ?>

WordPress主题开发内容相关编写 (https://www.wpmee.com/) WordPress开发教程 第1张

<?php comments_popup_link('0 条评论', '1 条评论', '% 条评论', '', '评论已关闭'); ?>

基本上,一个页面的内容已经包括了,大家根据自己的需求自定义的Diy

<?php the_title(); ?> 输出文章的标题

<?php else : ?>

<?php endif; ?>

<?php the_excerpt(); ?>

分页

显示评论数

内容

添加文章内容

<?php the_tags('标签:', ', ', ''); ?> 标签

<?php the_permalink(); ?> 输出文章的URL链接

接下来说下单页

</div>

添加日期

<?php if (have_posts()) : while (have_posts()) : the_post(); ?>

<a href="<?php the_permalink(); ?>">阅读全文</a>

<?php get_sidebar(); ?>

<?php else : ?>

函数详解

文章循环

输出找不到文章

<?php edit_post_link('编辑', ' • ', ''); ?>

内容

<?php the_tags('标签:', ', ', ''); ?>

可以直接很使用如下

<?php the_content('阅读全文...'); ?>

本站内容来源于网络,如有侵权请与我们联系,我们会及时删除,我们深感抱歉!
注:本站所有信息仅供学习参考!
本文地址为 https://v30.fanwenzhu.com/jz/wp/3972.shtml

相关文章

风云图片

推荐阅读

返回WordPress频道首页